package com.chenyaowei.order.service;

import com.chenyaowei.common.core.domain.AjaxResult;
import com.chenyaowei.order.domain.CywOrderItem;
import com.chenyaowei.order.request.OrderCommentReplyRequest;
import com.chenyaowei.order.request.OrderCommentRequest;

import java.util.List;

/**
 * 订单项信息Service接口
 *
 * @author 陈耀威
 * @date 2023-12-03
 */
public interface ICywOrderItemService
{
    /**
     * 查询订单项信息
     *
     * @param id 订单项信息主键
     * @return 订单项信息
     */
    public CywOrderItem selectCywOrderItemById(Long id);

    /**
     * 查询订单项信息列表
     *
     * @param cywOrderItem 订单项信息
     * @return 订单项信息集合
     */
    public List<CywOrderItem> selectCywOrderItemList(CywOrderItem cywOrderItem);

    /**
     * 新增订单项信息
     *
     * @param cywOrderItem 订单项信息
     * @return 结果
     */
    public int insertCywOrderItem(CywOrderItem cywOrderItem);

    /**
     * 修改订单项信息
     *
     * @param cywOrderItem 订单项信息
     * @return 结果
     */
    public int updateCywOrderItem(CywOrderItem cywOrderItem);

    /**
     * 批量删除订单项信息
     *
     * @param ids 需要删除的订单项信息主键集合
     * @return 结果
     */
    public int deleteCywOrderItemByIds(Long[] ids);

    /**
     * 删除订单项信息信息
     *
     * @param id 订单项信息主键
     * @return 结果
     */
    public int deleteCywOrderItemById(Long id);

    void saveBatch(List<CywOrderItem> orderItems);

    List<CywOrderItem> selectListByOrderSn(String orderSn);

    List<CywOrderItem> selectListByOrderSns(List<String> orderSns);

    AjaxResult addComment(OrderCommentRequest orderCommentRequest);

    int addCommentReply(OrderCommentReplyRequest orderCommentReplyRequest);
}
